Optimal. Leaf size=117 \[ \frac{2 b \tan ^{-1}\left (\frac{a \tan \left (\frac{1}{2} (e+f x)\right )+b}{\sqrt{a^2-b^2}}\right )}{f \sqrt{a^2-b^2} (b c-a d)}-\frac{2 d \tan ^{-1}\left (\frac{c \tan \left (\frac{1}{2} (e+f x)\right )+d}{\sqrt{c^2-d^2}}\right )}{f \sqrt{c^2-d^2} (b c-a d)} \]
[Out]
________________________________________________________________________________________
Rubi [A] time = 0.153368, antiderivative size = 117, normalized size of antiderivative = 1., number of steps used = 7, number of rules used = 4, integrand size = 25, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.16, Rules used = {2747, 2660, 618, 204} \[ \frac{2 b \tan ^{-1}\left (\frac{a \tan \left (\frac{1}{2} (e+f x)\right )+b}{\sqrt{a^2-b^2}}\right )}{f \sqrt{a^2-b^2} (b c-a d)}-\frac{2 d \tan ^{-1}\left (\frac{c \tan \left (\frac{1}{2} (e+f x)\right )+d}{\sqrt{c^2-d^2}}\right )}{f \sqrt{c^2-d^2} (b c-a d)} \]
Antiderivative was successfully verified.
[In]
[Out]
Rule 2747
Rule 2660
Rule 618
Rule 204
Rubi steps
\begin{align*} \int \frac{1}{(a+b \sin (e+f x)) (c+d \sin (e+f x))} \, dx &=\frac{b \int \frac{1}{a+b \sin (e+f x)} \, dx}{b c-a d}-\frac{d \int \frac{1}{c+d \sin (e+f x)} \, dx}{b c-a d}\\ &=\frac{(2 b) \operatorname{Subst}\left (\int \frac{1}{a+2 b x+a x^2} \, dx,x,\tan \left (\frac{1}{2} (e+f x)\right )\right )}{(b c-a d) f}-\frac{(2 d) \operatorname{Subst}\left (\int \frac{1}{c+2 d x+c x^2} \, dx,x,\tan \left (\frac{1}{2} (e+f x)\right )\right )}{(b c-a d) f}\\ &=-\frac{(4 b) \operatorname{Subst}\left (\int \frac{1}{-4 \left (a^2-b^2\right )-x^2} \, dx,x,2 b+2 a \tan \left (\frac{1}{2} (e+f x)\right )\right )}{(b c-a d) f}+\frac{(4 d) \operatorname{Subst}\left (\int \frac{1}{-4 \left (c^2-d^2\right )-x^2} \, dx,x,2 d+2 c \tan \left (\frac{1}{2} (e+f x)\right )\right )}{(b c-a d) f}\\ &=\frac{2 b \tan ^{-1}\left (\frac{b+a \tan \left (\frac{1}{2} (e+f x)\right )}{\sqrt{a^2-b^2}}\right )}{\sqrt{a^2-b^2} (b c-a d) f}-\frac{2 d \tan ^{-1}\left (\frac{d+c \tan \left (\frac{1}{2} (e+f x)\right )}{\sqrt{c^2-d^2}}\right )}{(b c-a d) \sqrt{c^2-d^2} f}\\ \end{align*}
Mathematica [A] time = 0.165576, size = 104, normalized size = 0.89 \[ \frac{\frac{2 b \tan ^{-1}\left (\frac{a \tan \left (\frac{1}{2} (e+f x)\right )+b}{\sqrt{a^2-b^2}}\right )}{\sqrt{a^2-b^2}}-\frac{2 d \tan ^{-1}\left (\frac{c \tan \left (\frac{1}{2} (e+f x)\right )+d}{\sqrt{c^2-d^2}}\right )}{\sqrt{c^2-d^2}}}{b c f-a d f} \]
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [A] time = 0.09, size = 116, normalized size = 1. \begin{align*} 2\,{\frac{d}{f \left ( da-cb \right ) \sqrt{{c}^{2}-{d}^{2}}}\arctan \left ( 1/2\,{\frac{2\,c\tan \left ( 1/2\,fx+e/2 \right ) +2\,d}{\sqrt{{c}^{2}-{d}^{2}}}} \right ) }-2\,{\frac{b}{f \left ( da-cb \right ) \sqrt{{a}^{2}-{b}^{2}}}\arctan \left ( 1/2\,{\frac{2\,a\tan \left ( 1/2\,fx+e/2 \right ) +2\,b}{\sqrt{{a}^{2}-{b}^{2}}}} \right ) } \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [F(-2)] time = 0., size = 0, normalized size = 0. \begin{align*} \text{Exception raised: ValueError} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [A] time = 10.3949, size = 2238, normalized size = 19.13 \begin{align*} \text{result too large to display} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [F(-1)] time = 0., size = 0, normalized size = 0. \begin{align*} \text{Timed out} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [F] time = 0., size = 0, normalized size = 0. \begin{align*} \mathit{sage}_{0} x \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]